<template>
	<view class="content">

		<i-pay-type :fontSize='20' border-color='#2a1' :datas='datas' class="paytype_box" @itemClick='itemClick'  @change='change'></i-pay-type>
		
	</view>
</template>

<script>
	export default {
		data() {
			return {
				title: 'Hello',
				datas:[{
					name: '支付宝',
					id: 'alipay',
					loading: true,
					img: '../../static/alipay.png',
				}, {
					name: '微信',
					id: 'wxpay',
					loading: false,
					img: '../../static/weixin.png'
				}, {
					name: '京东',
					id: 'wxpay1',
					loading: false,
					img: '../../static/logo.png'
				}]
			}
		},
		onLoad() {

		},
		methods: {
			change(e,b) {
				console.log(e,b)
				uni.showToast({
					title:b.name
				})
			},
			itemClick(e ,b){
				console.log(e,b)
			}
			
		}
	}
</script>

<style>
	.paytype_box{
		padding: 20rpx;
	}

</style>
